/* pages/anybiting/index.less */
/* 基于全局设计系统的样式优化 */

// 导入全局样式变量
@import '../../app.less';

/* 基础容器样式 */
.anybiting-container {
  width: 100%;
  height: 100vh;
  position: relative;
  overflow: hidden;
  background-color: @bg-primary;
}

/* 地图背景样式 */
.map-background {
  position: absolute;
  top: 0;
  left: 0;
  z-index: 1;
}

/* 地图半透明覆盖层 */
.map-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(to bottom, rgba(255,255,255,0.1) 0%, rgba(0,0,0,0.15) 100%);
  z-index: 2;
  pointer-events: none;
}
/* 聊天容器样式 */
.chat-container {
  width: 100%;
  height: calc(100vh - @spacing-xxl);
  padding-top: @spacing-xxl;
  position: relative;
  z-index: 10;
  overflow: hidden;
  transform: translateX(0);
  transition: transform @transition-normal;
  background-color: @bg-primary
}

/* 消息列表样式 */
.message-list {
  width: 100%;
  height: calc(100vh - @spacing-xxl);
  padding: @spacing-sm;
  box-sizing: border-box;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

/* 图表样式 */
.chart-container {
  width: 100%;
  padding: 10rpx 0;
}

.chart-title {
  font-size: 28rpx;
  text-align: center;
  margin-bottom: 15rpx;
  color: #666;
}

.bar-chart {
  display: flex;
  align-items: flex-end;
  height: 200rpx;
  gap: 15rpx;
  padding-bottom: 30rpx;
  position: relative;
}

.chart-bar {
  flex: 1;
  background-color: #673ab7;
  border-radius: 4rpx 4rpx 0 0;
  position: relative;
  min-width: 30rpx;
}

.chart-bar text {
  position: absolute;
  bottom: -30rpx;
  left: 50%;
  transform: translateX(-50%);
  font-size: 26rpx;
  color: #666;
}

/* 悬浮按钮样式 */
.float-button {
  position: fixed;
  width: 120rpx;
  height: 120rpx;
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  box-shadow: 0 5rpx 15rpx rgba(0,0,0,0.2);
  z-index: 999;
  transition: all 0.3s ease;
}

.float-button:active {
  transform: scale(0.95);
  box-shadow: 0 3rpx 10rpx rgba(0,0,0,0.15);
}

.button-icon {
  width: 60rpx;
  height: 60rpx;
}

.button-icon image {
  width: 100%;
  height: 100%;
}

/* 右下角书写按钮 */
.write-button {
  right: 40rpx;
  bottom: 60rpx;
  background-color: #07c160;
}

/* 左下角地图切换按钮 */
.map-toggle-button {
  left: 40rpx;
  bottom: 60rpx;
  background-color: #4285f4;
}

/* 滚动条样式 */
::-webkit-scrollbar {
  width: 6rpx;
}

::-webkit-scrollbar-track {
  background: transparent;
}

::-webkit-scrollbar-thumb {
  background-color: rgba(0, 0, 0, 0.1);
  border-radius: 3rpx;
}
.grid-container {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: @spacing-sm;
}

/* 城市选择器样式 */
.city-selector-mask {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0, 0, 0, 0.5);
  z-index: 998;
  animation: fadeIn 0.3s ease;
}

.city-selector-panel {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background-color: #fff;
  border-top-left-radius: 30rpx;
  border-top-right-radius: 30rpx;
  z-index: 999;
  max-height: 80vh;
  overflow-y: auto;
  animation: slideUp 0.3s ease;
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@keyframes slideUp {
  from {
    transform: translateY(100%);
  }
  to {
    transform: translateY(0);
  }
}

/* 城市选择器头部 */
.city-selector-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 30rpx 40rpx;
  border-bottom: 1rpx solid #f0f0f0;
}

.city-selector-title {
  font-size: 36rpx;
  font-weight: bold;
  color: #333;
}

.city-selector-close {
  font-size: 40rpx;
  color: #999;
  padding: 10rpx;
}

/* 搜索框样式 */
.city-search-box {
  padding: 20rpx 40rpx;
}

.search-input-wrapper {
  display: flex;
  align-items: center;
  background-color: #f5f5f5;
  border-radius: 40rpx;
  padding: 20rpx 30rpx;
}

.search-icon {
  width: 36rpx;
  height: 36rpx;
  margin-right: 20rpx;
}

.search-input-wrapper input {
  flex: 1;
  font-size: 32rpx;
  color: #333;
  background: transparent;
}

.search-placeholder {
  color: #999;
}

/* 城市列表样式 */
.section-title {
  font-size: 28rpx;
  color: #999;
  margin: 20rpx 40rpx 10rpx;
}

.city-list {
  padding: 0 40rpx 20rpx;
}

.city-item {
  padding: 30rpx 0 0 50rpx;
  font-size: 32rpx;
  color: #333;
  border-bottom: 1rpx solid #f0f0f0;
}

.city-item:last-child {
  border-bottom: none;
}

.current-city {
  color: #07c160;
  font-weight: bold;
}

/* 热门城市网格 */
.city-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20rpx;
  padding: 0 40rpx 30rpx;
}

.city-grid-item {
  background-color: #f5f5f5;
  border-radius: 10rpx;
  padding: 25rpx 0;
  text-align: center;
  font-size: 32rpx;
  color: #333;
}

/* 当前城市 */
.city-current {
  padding: 0 0 40rpx;
}

/* 适配暗黑模式 */
@media (prefers-color-scheme: dark) {
  .city-selector-panel {
    background-color: #222;
  }
  
  .city-selector-title {
    color: #fff;
  }
  
  .city-selector-close {
    color: #666;
  }
  
  .search-input-wrapper {
    background-color: #444;
  }
  
  .search-input-wrapper input {
    color: #fff;
  }
  
  .search-placeholder {
    color: #666;
  }
  
  .section-title {
    color: #666;
  }
  
  .city-item {
    color: #fff;
    border-bottom: 1rpx solid #444;
  }
  
  .current-city {
    color: #07c160;
  }
  
  .city-grid-item {
    background-color: #444;
    color: #fff;
  }
}